import React from 'react';
import ReactDOM from 'react-dom';
import { ChakraProvider, CSSReset } from '@chakra-ui/react';
import theme from '@chakra-ui/theme';
import App from './App';
import LaGouComponents from './LaGou';

// 1. 设置默认颜色模式
// theme.config.initialColorMode = 'dark';

// 2. 使用操作系统所使用的颜色模式
// theme.config.useSystemColorMode = true;

const myTheme = {
  ...theme,
  components: {
    ...theme.components,
    ...LaGouComponents
  }
}

ReactDOM.render(
  <ChakraProvider theme={myTheme}>
    <CSSReset/>
    <App />
  </ChakraProvider>,
  document.getElementById('root')
);